/**
 * Author: zhezhen.cheng
 * Creation Time: 2016/6/14.
 * Description:...
 */
define(['jquery'],
    function ($) {
        function example(datas,type) {

            var txt='';
            for(var i=0;i<datas.data.productInfos.length;i++) {
                txt += '<li data-id="'+datas.data.productInfos[i].id+'">' +
                    '<div class="ui-tab-content-goods-box">' +
                    '<img src="'+datas.data.productInfos[i].headUrl+'">' +
                    '<div class="ui-tab-content-goods-box-des">' +
                    '<span>'+datas.data.productInfos[i].name+'</span>' +
                    '</div>' +
                    '<div class="webApp-content-price">' +
                    '<span>￥'+datas.data.productInfos[i].price+'</span>' +
                    '<i style="float: right"></i>' +
                    '</div>' +
                    '</div>' +
                    '</li>';
            }
            if(type==1){
                $('.webApp-iphone').html(txt);
                $('.webApp-iphone').removeClass('hidden');
            }
            else if(type==2){
                $('.webApp-other').html(txt);
                $('.webApp-other').removeClass('hidden');
            }
            else{

            }

        }

        return example;
    });
